import type {
  GovernanceProposal,
  TreasuryTransaction,
} from '../../types/zhu-family';

/**
 * 治理提案数据
 */
export const governanceProposals: GovernanceProposal[] = [
  {
    id: 'prop-1',
    title: '设立皇族教育基金',
    description:
      '提议从中央国库拨款 500 万两白银设立教育基金，用于资助皇族子弟及优秀学子求学',
    proposer: '朱瞻基',
    proposerKingdom: 'central',
    createTime: '1430-01-15T10:00:00Z',
    voteEndTime: '1430-02-15T10:00:00Z',
    type: 'finance',
    status: 'voting',
    votesFor: 8,
    votesAgainst: 2,
    votesRequired: 10,
    voters: [
      {
        memberId: 'zhu-1',
        memberName: '朱元璋',
        memberKingdom: 'central',
        vote: 'for',
        weight: 3,
        voteTime: '1430-01-16T09:00:00Z',
      },
      {
        memberId: 'zhu-2-4',
        memberName: '朱棣',
        memberKingdom: 'yan',
        vote: 'for',
        weight: 2,
        voteTime: '1430-01-16T10:30:00Z',
      },
      {
        memberId: 'zhu-2-5',
        memberName: '朱橚',
        memberKingdom: 'zhou',
        vote: 'for',
        weight: 2,
        voteTime: '1430-01-16T14:00:00Z',
      },
      {
        memberId: 'zhu-2-6',
        memberName: '朱桢',
        memberKingdom: 'chu',
        vote: 'against',
        weight: 1,
        voteTime: '1430-01-17T11:00:00Z',
      },
      {
        memberId: 'zhu-4-1',
        memberName: '朱瞻基',
        memberKingdom: 'central',
        vote: 'for',
        weight: 2,
        voteTime: '1430-01-15T10:00:00Z',
      },
    ],
  },
  {
    id: 'prop-2',
    title: '修订《大明会典》关于藩王礼制条款',
    description:
      '建议修订藩王礼制，明确各藩王封地治理权限，加强中央对地方的监管',
    proposer: '朱高炽',
    proposerKingdom: 'central',
    createTime: '1430-01-20T14:00:00Z',
    voteEndTime: '1430-02-20T14:00:00Z',
    type: 'law',
    status: 'voting',
    votesFor: 5,
    votesAgainst: 3,
    votesRequired: 10,
    voters: [
      {
        memberId: 'zhu-2-4',
        memberName: '朱棣',
        memberKingdom: 'yan',
        vote: 'for',
        weight: 2,
        voteTime: '1430-01-21T09:00:00Z',
      },
      {
        memberId: 'zhu-2-2',
        memberName: '朱樉',
        memberKingdom: 'qin',
        vote: 'against',
        weight: 1,
        voteTime: '1430-01-21T10:00:00Z',
      },
      {
        memberId: 'zhu-3-2',
        memberName: '朱高炽',
        memberKingdom: 'central',
        vote: 'for',
        weight: 2,
        voteTime: '1430-01-20T14:00:00Z',
      },
      {
        memberId: 'zhu-2-7',
        memberName: '朱椿',
        memberKingdom: 'shu',
        vote: 'against',
        weight: 1,
        voteTime: '1430-01-22T15:00:00Z',
      },
    ],
  },
  {
    id: 'prop-3',
    title: '增设北方边防军备',
    description: '鉴于北方蒙古势力频繁侵扰，提议增拨军费 300 万两用于加强边防',
    proposer: '朱棡',
    proposerKingdom: 'jin',
    createTime: '1430-02-01T10:00:00Z',
    voteEndTime: '1430-03-01T10:00:00Z',
    type: 'military',
    status: 'voting',
    votesFor: 7,
    votesAgainst: 1,
    votesRequired: 10,
    voters: [
      {
        memberId: 'zhu-2-3',
        memberName: '朱棡',
        memberKingdom: 'jin',
        vote: 'for',
        weight: 1,
        voteTime: '1430-02-01T10:00:00Z',
      },
      {
        memberId: 'zhu-2-4',
        memberName: '朱棣',
        memberKingdom: 'yan',
        vote: 'for',
        weight: 2,
        voteTime: '1430-02-01T15:00:00Z',
      },
      {
        memberId: 'zhu-4-1',
        memberName: '朱瞻基',
        memberKingdom: 'central',
        vote: 'for',
        weight: 2,
        voteTime: '1430-02-02T09:00:00Z',
      },
      {
        memberId: 'zhu-2-7',
        memberName: '朱椿',
        memberKingdom: 'shu',
        vote: 'abstain',
        weight: 1,
        voteTime: '1430-02-03T11:00:00Z',
      },
    ],
  },
  {
    id: 'prop-4',
    title: '祭祖大典筹备方案',
    description:
      '提议于洪武三十年（1430年）秋举行皇族祭祖大典，祭拜太祖高皇帝，各藩王需回京参加',
    proposer: '朱瞻基',
    proposerKingdom: 'central',
    createTime: '1430-02-10T10:00:00Z',
    voteEndTime: '1430-03-10T10:00:00Z',
    type: 'ceremony',
    status: 'voting',
    votesFor: 9,
    votesAgainst: 0,
    votesRequired: 10,
    voters: [
      {
        memberId: 'zhu-4-1',
        memberName: '朱瞻基',
        memberKingdom: 'central',
        vote: 'for',
        weight: 2,
        voteTime: '1430-02-10T10:00:00Z',
      },
      {
        memberId: 'zhu-2-2',
        memberName: '朱樉',
        memberKingdom: 'qin',
        vote: 'for',
        weight: 1,
        voteTime: '1430-02-11T09:00:00Z',
      },
      {
        memberId: 'zhu-2-3',
        memberName: '朱棡',
        memberKingdom: 'jin',
        vote: 'for',
        weight: 1,
        voteTime: '1430-02-11T10:00:00Z',
      },
      {
        memberId: 'zhu-2-5',
        memberName: '朱橚',
        memberKingdom: 'zhou',
        vote: 'for',
        weight: 2,
        voteTime: '1430-02-11T14:00:00Z',
      },
      {
        memberId: 'zhu-2-6',
        memberName: '朱桢',
        memberKingdom: 'chu',
        vote: 'for',
        weight: 1,
        voteTime: '1430-02-12T09:00:00Z',
      },
      {
        memberId: 'zhu-2-7',
        memberName: '朱椿',
        memberKingdom: 'shu',
        vote: 'for',
        weight: 1,
        voteTime: '1430-02-12T15:00:00Z',
      },
    ],
  },
];

/**
 * 国库交易记录
 */
export const treasuryTransactions: TreasuryTransaction[] = [
  {
    id: 'tx-1',
    fromKingdom: 'central',
    toKingdom: 'zhou',
    amount: 500_000,
    type: 'grant',
    description: '拨款支持周藩编撰《救荒本草》',
    createTime: '1429-06-15T10:00:00Z',
    status: 'executed',
    signatures: ['zhu-1', 'zhu-2-4', 'zhu-3-2'],
    requiredSignatures: 3,
  },
  {
    id: 'tx-2',
    fromKingdom: 'chu',
    toKingdom: 'central',
    amount: 800_000,
    type: 'tribute',
    description: '楚藩年贡',
    createTime: '1429-12-01T10:00:00Z',
    status: 'executed',
    signatures: ['zhu-2-6', 'zhu-3-2'],
    requiredSignatures: 2,
  },
  {
    id: 'tx-3',
    fromKingdom: 'central',
    toKingdom: 'jin',
    amount: 1_000_000,
    type: 'military',
    description: '北疆防务军费拨款',
    createTime: '1430-01-10T10:00:00Z',
    status: 'confirmed',
    signatures: ['zhu-2-4', 'zhu-4-1'],
    requiredSignatures: 3,
  },
  {
    id: 'tx-4',
    fromKingdom: 'shu',
    toKingdom: 'central',
    amount: 600_000,
    type: 'tribute',
    description: '蜀藩年贡',
    createTime: '1430-01-20T10:00:00Z',
    status: 'pending',
    signatures: ['zhu-2-7'],
    requiredSignatures: 2,
  },
  {
    id: 'tx-5',
    fromKingdom: 'central',
    toKingdom: 'qin',
    amount: 300_000,
    type: 'grant',
    description: '西北屯田补助',
    createTime: '1430-02-05T10:00:00Z',
    status: 'pending',
    signatures: [],
    requiredSignatures: 3,
  },
];
